package com.ljz.controller;

import com.ljz.common.core.controller.MyBaseController;
import com.ljz.common.dao.bean.PageParam;
import com.ljz.common.dao.bean.PageResult;
import com.ljz.common.utils.ReturnResult;
import com.ljz.entity.User;
import com.ljz.query.UserQuery;
import com.ljz.service.UserService;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/api/sys")
@Api(tags = "用户管理")
public class UserController extends MyBaseController {

    @Autowired
    UserService userService;


    @PostMapping("/user")
    public ReturnResult<PageResult> query(@RequestBody UserQuery userQuery) {

        PageResult rs =  userService.queryByPage(userQuery);

        return success("用户列表",rs);
    }

}
